/*******************************************************************************
 * Copyright (c) 2007 University of Oslo.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     University of Oslo - initial API and implementation
 *******************************************************************************/

package com.cea.papyrus.diagram.sequence.sedi.model.command;

import org.eclipse.uml2.uml.NamedElement;

/**
 * Identifies the exact position (in terms of the UML model) for a MessageEnd.
 * Exactly how a MessageEnd is specified varies:
 * <ul>
 *   <li>Gates on Interactions, InteractionUses or CombinedFragments are 
 *       specified simply with a reference to the fragment. The exact position 
 *       of gates is not important in the current implementation. 
 *   <li>MessageEnds on lifelines are more complex, as several coordinates
 *       are needed:
 *       <ol>
 *         <li>A reference to the interaction operand that encloses the
 *             lifeline at the endpoint.
 *         <li>An index into the lifeline's CoveredBy attribute.
 *       </ol>
 * </ul> 
 * 
 * @author frankd@ifi.uio.no
 */
public class MessageEndPosition {
	
	/**
	 * The owner of the MessageEnd. This model element will contain the
	 * MessageEnd as one of its children. For example, for InteractionUses
	 * the MessageEnd will belong among the InteractionUse's gates. 
	 */
	private NamedElement owner;
	
	public MessageEndPosition() {
	}
	public MessageEndPosition(final NamedElement owner) {
		this.owner = owner;
	}

	public NamedElement getOwner() {
		return owner;
	}
	public void setOwner(final NamedElement owner) {
		this.owner = owner;
	}
}

